home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / macros / text1 / wsuipa / iaccent.mf < prev    next >
Text File  |  1991-10-23  |  11KB  |  307 lines

  1. % This is IACCENT.MF in text format, as of April 22, 1989.
  2. % This file contains accents common to text roman and italic fonts.
  3. % Character codes \0022--\0030, \0040, \0136--\0137, \0175--\0177 are generated.
  4.  
  5. % (Actually the accents in positions \0040, \0137, and \0175 are not generated
  6. % unless |ligs>0|, since other symbols are substituted
  7. % for those accents in non-ligature fonts.)
  8.  
  9.  
  10. cmchar "Reversed Apostrophe";
  11. beginchar(oct"163",5u#,asc_height#,0);
  12. italcorr asc_height#*slant+.5dot_size#-2u#;
  13. adjust_fit(0,0);
  14. x1-.5dot_size=hround(.5w-.5dot_size); y1+.5dot_size=h;
  15. def mymoc(suffix $,@)(expr dot_size,jut,depth) = % reversed comma
  16.  pickup fine.nib; pos$(dot_size,90);
  17.   pos@1(vair,90); pos@2(vair,180); pos@3(vair,-45);
  18.   z@1r=z$r; rt x@2r=hround(x$-.5dot_size-jut)-2eps; x@3=x$+.5u;
  19.   y@2=1/3[y@1,y@3]; bot y@3l=vround(y$-.5dot_size-depth);
  20.   y_:=ypart((z@1{left}...z@2{down}...z@3)
  21.    intersectiontimes (z$l{left}..{right}z$r)); if y_<0: y_:=1; fi
  22.   filldraw z$r{right}..subpath (0,y_) of (z$l{left}..{right}z$r)--cycle; % dot
  23.   filldraw stroke z@1e{left}...z@2e{down}...z@3e;     % tail
  24.  penlabels(@1,@2,@3); enddef;
  25.  
  26. if monospace: mymoc(1,a,dot_size,.28u,vround 1.5comma_depth);  % large comma
  27. else: mymoc(1,a,dot_size,.25u,comma_depth); fi  % comma with increased jut
  28. penlabels(1); endchar;
  29.  
  30. cmchar "Corner accent";
  31. beginchar(oct"153",7u#,min(asc_height#,2x_height#),0);
  32. adjust_fit(0,0);
  33. pickup light_rule.nib;
  34. x1=1u; x2=x3=w-x1;
  35.  y1=h+eps=y2; y3=.87x_height;
  36.  draw z1--z2; draw z2--z3;   % corner
  37. penlabels(1,2,3); endchar;
  38.  
  39. cmchar "Scandinavian circle accent";
  40. beginchar(oct"170",13u#+4/3(asc_height#-x_height#)*slant,asc_height#,0);
  41. adjust_fit(cap_serif_fit#,cap_serif_fit#);
  42. numeric circ_hair,circ_vair;
  43. circ_hair=hround min(hair,u+.5); circ_vair=vround min(vair,(h-x_height)/6+.5);
  44. penpos1(circ_vair,90); penpos3(circ_vair,-90);
  45. penpos2(circ_hair,180); penpos4(circ_hair,0);
  46. x2r=hround(.5w-1.5u-.5circ_hair);
  47. x4r=w-x2r; x1=x3=.5w; y1r=h+apex_o; y2=y4=.5[y1,y3];
  48. y3r=vround(1/3[x_height,h]+apex_o);
  49. penstroke pulled_arc.e(1,2) & pulled_arc.e(2,3)
  50.  & pulled_arc.e(3,4) & pulled_arc.e(4,1) & cycle;  % bowl
  51. penlabels(1,2,3,4); endchar;
  52.  
  53. cmchar "Mid-Tilde (squiggle) accent";
  54. beginchar(oct"173",12u#,x_height#+.5dot_size#,0);
  55. italcorr h#*slant-u#;
  56. adjust_fit(0,0);
  57. if serifs: numeric theta; theta=angle(1/6(8u-vair),1/4(h-.62x_height));
  58.  pickup crisp.nib; numeric mid_width; mid_width=.4[vair,stem];
  59.  pos1(vair,theta+90); pos2(vair,theta+90);
  60.  pos3(vair,theta+90); pos4(vair,theta+90);
  61.  z2-z1=z4-z3=(mid_width-crisp)*dir theta;
  62.  lft x1r=w-rt x4l=hround 1.5u; top y4r=h;
  63.  bot y1l=vround(bot y1l+min(.6[.62x_height,h],y3l-.2vair)-top y1r);
  64.  pair delta; ypart delta=3(y3l-y1l); delta=whatever*dir theta;
  65.  filldraw z1l..controls(z1l+delta)and(z3l-delta)..z3l..z4l
  66.   --z4r..controls(z4r-delta)and(z2r+delta)..z2r..z1r--cycle;  % stroke
  67. else: pickup fine.nib; pos1(vair,180); pos2(vair,90);
  68.  pos3(.5[vair,slab],90); pos4(vair,90); pos5(vair,180);
  69.  lft x1r=w-rt x5l=hround 1.5u; x2-x1=x3-x2=x4-x3=x5-x4;
  70.  bot y1=bot y4l=vround(.75[.62x_height,h]-vair);
  71.  top y2r=top y5=h; y3=.5[y2,y4];
  72.  filldraw stroke z1e{up}...z2e{right}..z3e..{right}z4e...{up}z5e; fi % stroke
  73. penlabels(1,2,3,4,5); endchar;
  74.  
  75. cmchar "Polish hook accent";
  76. beginchar(oct"176",8u#,0,.875desc_depth#);
  77. adjust_fit(0,0);
  78. x1=.5w+.5u;
  79. if serifs: pickup crisp.nib; pos1(stem,0); pos2(stem,0);
  80.  pos3(vair,90); pos4(stem,0); pos5(vair,-90);
  81.  x1=x2; z3l=z2l; x4=x2+1.5u; x5=x3-1.5u;
  82.  bot y1=-o; bot y2=-vround 2/7d-o; y4=.5[y3,y5]; bot y5=-d-o;
  83.  filldraw stroke z1e--z2e;  % stem
  84.  filldraw stroke z3e{right}...z4e{down}...{left}z5e;  % hook
  85. else: pickup fine.nib; pos1(vair,0); top y1=-o-2;
  86.  pos2(.5[vair,stem],0); bot y2=-d-o; x2=x1-1.25u;
  87.  filldraw stroke z1e--z2e; fi  % diagonal
  88. currentpicture:= currentpicture reflectedabout((.5w,0),(.5w,d));
  89. penlabels(1,2,3,4,5); endchar;
  90.  
  91. cmchar "Half-length Mark";
  92. beginchar(oct"160",5.8u#,x_height#,0);
  93. adjust_fit(0,0); pickup rule.nib;
  94. lft x1=hround 1.1u; x2=w-x1; x3=.5w;
  95. y2=good.y h+o=y1; bot y3=.57h;
  96. filldraw z1---z2---z3---cycle;  % triangle
  97. labels(1,2,3); endchar;
  98.  
  99. cmchar "Length Mark";
  100. beginchar(oct"161",5.8u#,x_height#,0);
  101. adjust_fit(0,0); pickup rule.nib;
  102. lft x1=hround 1.1u=lft x5; x2=w-x1=x6; x3=.5w=x4;
  103. top y4=vround .43h; y5=y6=0;
  104. y2=good.y h+o=y1; bot y3=.57h;
  105. filldraw z1---z2---z3---cycle;  % triangle
  106. filldraw z4---z5---z6---cycle;  % triangle
  107. labels(1,2,3,4,5,6); endchar;
  108.  
  109. cmchar "Subscript Bridge";
  110. beginchar(oct"147",7u#,0,1.1desc_depth#);
  111. adjust_fit(0,0); pickup light_rule.nib;
  112. lft x1=hround 1.1u; x2=x1; x4=x5=w-x1;
  113. y2=good.y -.3d-o; bot y1=-d; y4=y2; y5=y1;
  114. draw z2---z1;  % stems and bar
  115. draw z2---z4;
  116. draw z5---z4;  % stems and bar
  117. labels(1,2,4,5); endchar;
  118.  
  119. cmchar "Under-ring";
  120. beginchar(oct"171",13u#+4/3(asc_height#-x_height#)*slant,0,1.3desc_depth#);
  121. adjust_fit(cap_serif_fit#,cap_serif_fit#);
  122. numeric circ_hair,circ_vair;
  123. circ_hair=hround min(hair,u+.5);
  124. circ_vair=vround min(vair,(-d-x_height)/6+.5);
  125. penpos1(vair,90); penpos3(vair,-90);
  126. penpos2(hair,180); penpos4(hair,0);
  127. x2r=hround(.5w-1.5u-.5hair);
  128. x4r=w-x2r; x1=x3=.5w; y1r=-.2d-apex_o; y2=y4=.5[y1,y3];
  129. y3r=vround(-d-apex_o);
  130. penstroke pulled_arc.e(1,2) & pulled_arc.e(2,3)
  131.  & pulled_arc.e(3,4) & pulled_arc.e(4,1) & cycle;  % bowl
  132. penlabels(1,2,3,4); endchar;
  133.  
  134. cmchar "Subscript Umlaut (double dot) accent";
  135. numeric dot_diam#,dot_diam;
  136. dot_diam#=max(dot_size#,cap_curve#);
  137. beginchar(oct"162",9u#,0,min(desc_depth#,10/7x_height#+.5dot_diam#));
  138. dot_diam=max(tiny.breadth,hround(max(dot_size,cap_curve)-2stem_corr));
  139. italcorr h#*slant+.5dot_diam#-2.25u#;
  140. adjust_fit(0,0);
  141. pickup tiny.nib; pos1(dot_diam,0); pos2(dot_diam,90);
  142. x1=x2=2.75u; top y2r=-.3d-1;
  143. if bot y2l<-desc_depth-o-slab:
  144.             y2l:=min(y2r-eps,-desc_depth-o-slab+.5tiny); fi
  145. y1=.5[y2l,y2r]; dot(1,2);  % left dot
  146. pos3(dot_diam,0); penpos4(y2r-y2l,90); y3=y4=y1; x3=x4=w-x1;
  147. dot(3,4);  % right dot
  148. penlabels(1,2,3,4); endchar;
  149.  
  150. cmchar "Subscript Left Half-ring";
  151. beginchar(oct"172",13u#+4/3(asc_height#-x_height#)*slant,0,1.2desc_depth#);
  152. adjust_fit(cap_serif_fit#,cap_serif_fit#);
  153. penpos1(cap_hair+stem_corr,90); penpos3(cap_hair+stem_corr,-90);
  154. penpos2(cap_hair+stem_corr,180);
  155. x2r=hround(.5w-1.5u-.5hair);
  156. x1=x3=.58w; top y1r=-.15d-apex_o; y2=.5[y1,y3];
  157. y3r=vround(-d-apex_o);
  158. %penstroke pulled_arc.e(1,2) & pulled_arc.e(2,3);  % bowl
  159. penstroke z1e{left}...{down}z2e{down}...{right}z3e;
  160. penlabels(1,2,3); endchar;
  161.  
  162. cmchar "Under tilde (squiggle) accent";
  163. beginchar(oct"174",12u#,0, 1.1desc_depth#);
  164. italcorr d#*slant-u#;
  165. adjust_fit(0,0);
  166. if serifs: numeric theta;
  167. theta=angle(1/6(8u-vair),1/3(h+desc_depth));
  168.  pickup crisp.nib; numeric mid_width; mid_width=.4[vair,stem];
  169.  pos1(vair,theta+90); pos2(vair,theta+90);
  170.  pos3(vair,theta+90); pos4(vair,theta+90);
  171.  z2-z1=z4-z3=(mid_width-crisp)*dir theta;
  172.  lft x1r=w-rt x4l=hround 1.5u; top y4r=-.3d+vair;
  173.  bot y1l=vround(bot y1l+min(.4[-d,-.15d],y3l-.35vair)-top y1r);
  174.  pair delta; ypart delta=3(y3l-y1l); delta=whatever*dir theta;
  175.  filldraw z1l..controls(z1l+delta)and(z3l-delta)..z3l..z4l
  176.   --z4r..controls(z4r-delta)and(z2r+delta)..z2r..z1r--cycle;  % stroke
  177. else: pickup fine.nib; pos1(vair,180); pos2(vair,90);
  178.  pos3(.5[vair,slab],90); pos4(vair,90); pos5(vair,180);
  179.  lft x1r=w-rt x5l=hround 1.5u; x2-x1=x3-x2=x4-x3=x5-x4;
  180.  bot y1=bot y4l=vround(-.76d-vair);
  181.  top y2r=top y5=-.2d; y3=.5[y2,y4];
  182.  filldraw stroke z1e{up}...z2e{right}..z3e..{right}z4e...{up}z5e; fi % stroke
  183. penlabels(1,2,3,4,5); endchar;
  184.  
  185. cmchar "Subscript Hachek (check) accent";
  186. beginchar(oct"175",9u#,0,desc_depth#);
  187. h':=vround -d; % height of circumflex being inverted
  188. if serifs: italcorr h#*slant+.5hair#-1.75u#;
  189.  adjust_fit(0,0);
  190.  pickup crisp.nib; pos2'(.4[vair,curve],90); top y2'r=h;
  191.  pos2(.4[vair,curve],90); x2=.5w;
  192.  x1=w-x3=good.x 2.25u; top y1=top y3=-.2d; y1-y2=-.5(y2'-d);
  193.  pos1(hair,angle(z2-z1)+90); pos3(hair,angle(z3-z2)+90);
  194.  filldraw stroke z1e--z2e--z3e;  % diagonals
  195. else: italcorr h#*slant-.5stem#+.5vair#-.75u#;
  196.  adjust_fit(0,0);
  197.  pickup fine.nib; pos1(vair,0); pos3(vair,0); x1=w-x3;
  198.  pos2(stem,0); bot y2=vround(1/12[-d,h']+o); x2=.5w;
  199.  top y1=top y3=-.1d+o; lft x1l=hround(rt x2r-3.25u-.5vair);
  200.  z0=whatever[z1r,z2r]=whatever[z2l,z3l];
  201.  y4l=y4r=y2; x4l=good.x .2[x2l,x2]; x4r=w-x4l;
  202.  filldraw z4l--z1l--z1r--z0--z3l--z3r--z4r--cycle; fi  % diagonals
  203. penlabels(0,1,2,3,4); endchar;
  204.  
  205.  
  206. cmchar "subscript arch (inverted breve)";
  207. beginchar(oct"177",9u#,0,desc_depth#);
  208. italcorr h#*slant+.5vair#-1.5u#;
  209. adjust_fit(0,0);
  210. pickup crisp.nib; pos1(vair,-180); pos3(vair,0);
  211. top y1=top y3=-d; lft x1r=w-rt x3r=hround(2u-.5vair);
  212. numeric mid_thickness; mid_thickness=vround 1/3[vair,stem];
  213. pos2(mid_thickness,90); x2=.5w;
  214. top y2r=vround max(-.15d-o-tiny,-.68mid_thickness);
  215. filldraw stroke z1e{up}...z2e{right}...{down}z3e;  % stroke
  216. penlabels(1,2,3); endchar;
  217.  
  218. cmchar "Vertical Stroke (superior)";
  219. beginchar(oct"150",4u#,asc_height#,0); pickup rule.nib;
  220. x1=x2=good.x .5w; top y1=h+eps; bot y2=x_height-eps;
  221. draw z1--z2;  % stem
  222. labels(1,2); endchar;
  223.  
  224. cmchar "Vertical Stroke (inferior)";
  225. beginchar(oct"151",4u#,.25x_height#,desc_depth#); pickup rule.nib;
  226. x1=x2=good.x .5w; top y1=h+eps; bot y2=-d-eps;
  227. draw z1--z2;  % stem
  228. labels(1,2); endchar;
  229.  
  230. cmchar "Syllabicity Mark";
  231. beginchar(oct"152",4u#,0,1.4desc_depth#); pickup rule.nib;
  232. x1=x2=good.x .5w; top y1=0-eps; bot y2=-d;
  233. draw z1--z2;  % stem
  234. labels(1,2); endchar;
  235.  
  236. cmchar "left pointer";
  237. beginchar(oct"166",8.2u#,asc_height#,0);
  238. italcorr h#*slant-u#;
  239. adjust_fit(0,0); pickup rule.nib;
  240. lft x2=hround 1.5u-eps; x1=x3=w-x2;
  241. y1=h; y3=.7h;
  242. y2=.5[y1,y3];
  243. draw z1--z2--z3;  % diagonals
  244. labels(1,2,3); endchar;
  245.  
  246. cmchar "right pointer";
  247. beginchar(oct"167",8.2u#,asc_height#,0);
  248. adjust_fit(0,0); pickup rule.nib;
  249. rt x2=hround(w-1.5u)+eps; x1=x3=w-x2;
  250. y1=h; y3=.7h;
  251. y2=.5[y1,y3];
  252. draw z1--z2--z3;  % diagonals
  253. labels(1,2,3); endchar;
  254.  
  255. cmchar "down pointer";
  256. beginchar(oct"165",8.2u#,asc_height#,0);
  257. adjust_fit(0,0); pickup rule.nib;
  258. lft x1=hround 1.5u-eps; x3=w-x1;
  259. x2=.5[x1,x3];
  260. y1=asc_height=y3; y2=1.1x_height;
  261. draw z1--z2--z3;  % diagonals
  262. labels(1,2,3); endchar;
  263.  
  264. cmchar "up pointer";
  265. beginchar(oct"164",8.2u#,asc_height#,0);
  266. adjust_fit(0,0); pickup rule.nib;
  267. lft x1=hround 1.5u-eps; x3=w-x1;
  268. x2=.5[x1,x3];
  269. y1=1.1x_height=y3; y2=asc_height;
  270. draw z1--z2--z3;  % diagonals
  271. labels(1,2,3); endchar;
  272.  
  273. cmchar "Bar down sign";
  274. beginchar(oct"155",8u#,x_height#,0); pickup rule.nib;
  275. x1=x2=.5w;
  276. lft x3=hround 0+eps; x4=w-x3; top y1=top y3=top y4=h-stem_corr;
  277. bot y2=0+u;
  278. draw z1--z2;  % stem
  279. draw z3--z4;  % crossbar
  280. labels(1,2,3,4); endchar;
  281.  
  282. cmchar "Bar up sign";
  283. beginchar(oct"154",8u#,x_height#,0); pickup rule.nib;
  284. x1=x2=good.x .5w; top y1=h-stem_corr;
  285. lft x3=hround 0+eps; x4=w-x3; bot y2=bot y3=bot y4=0+u;
  286. draw z1--z2;  % stem
  287. draw z3--z4;  % crossbar
  288. labels(1,2,3,4); endchar;
  289.  
  290.  
  291. cmchar "Bar right sign";
  292. beginchar(oct"157",8u#,x_height#,0); pickup rule.nib;
  293. lft x1=lft x2=hround 0+eps=lft x3; top y1=h-stem_corr;
  294. x4=w-x1; bot y2= u; y3=.5[y1,y2]=y4;
  295. draw z1--z2;  % stem
  296. draw z3--z4;  % crossbar
  297. labels(1,2,3,4); endchar;
  298.  
  299. cmchar "Bar Left sign";
  300. beginchar(oct"156",8u#,x_height#,0); pickup rule.nib;
  301. x1=x2=w-x4=x3; top y1=h-stem_corr;
  302. lft x4=hround 0+eps; bot y2=u;
  303. y3=.5[y1,y2]=y4;
  304. draw z1--z2;  % stem
  305. draw z3--z4;  % crossbar
  306. labels(1,2,3,4); endchar;
  307.